Mobile terminal, DC-charging power source adaptor, and charging method

ABSTRACT

The disclosure discloses a mobile terminal, a DC-charging power source adaptor, and a charging method, where the mobile terminal detects whether two communication pins of a USB interface thereof are shorted, and if an inserted external device is a power source adaptor, then the mobile terminal communicates with the power source adaptor, so that the mobile terminal identifies automatically the type of the externally connected charging device. Also a specialized rapid charging mode is designed for a DC-charging power adaptor, so that a battery being charged routinely is DC-charged at large current using charging voltage output by the DC-charging power source adaptor, and a volt value of the charging voltage is adjusted dynamically to the varying voltage of the battery core.

CROSS-REFERENCE TO RELATED APPLICATION

This application is a continuation of U.S. patent application Ser. No.15/064,010 filed Mar. 8, 2016, which claims the benefit and priority ofChinese Patent Application No. 201510473330.7 filed Aug. 5, 2015. Theentire disclosures of the above applications are incorporated herein byreference.

FIELD

The present disclosure relates to the field of Direct-Current (DC)charging and particularly to a method for charging a battery in a mobileterminal, and a mobile terminal and DC-charging power source adaptorsupporting the charging method.

BACKGROUND

This section provides background information related to the presentdisclosure which is not necessarily prior art.

At present, portable mobile terminals have been widely applied innumerous aspects of people's life, and have become a leading factor inthe development of the semiconductor industry. The majority of theexisting portable mobile terminals are provided with chargeablebatteries to power system circuits in the mobile terminals. As anincreasing number of functions supported by the portal mobile terminalsare emerging, their system circuits also consume more and more power,and given a limited capacity of the batteries, the mobile terminalsoperate for a shorter and shorter period of time after the batteries arecharged, so that the batteries have to be charged more and morefrequently.

At present the batteries have been widely charged in two generalschemes: in one of the schemes, the batteries are charged by a generalpower source adaptor (charger), i.e., in the normal DCP charging scheme,where the general power source adaptor generally supports an output ofonly fixed voltage, e.g., 5V, 9V, 12V, etc., so that the output voltagemay not be selectable flexibly; and in the other scheme, the batteriesare charged by a host (e.g., a computer, etc.), i.e., in the SDPcharging scheme.

SUMMARY

This section provides a general summary of the disclosure, and is not acomprehensive disclosure of its full scope or all of its features.

An embodiment of the disclosure provides a method for charging a mobileterminal, the method including: determining, by the mobile terminal,whether two differential data pins of a USB interface thereof areshorted, upon detecting an external device being inserted into the USBinterface; if so, then communicating with the inserted external device;if the external device is a DC-charging power source adaptor, thenswitching, by the DC-charging power source adaptor, two communicationpins of a charging interface thereof from being shorted by default tobeing disconnected, and communicating with the mobile terminal; anddetecting, by the mobile terminal, voltage of the battery aftercommunicating successfully with the DC-charging power source adaptor,and if the voltage of a battery core lies in a range delimited by presetDC-charging thresholds, then charging the battery directly usingcharging voltage output by the DC-charging power source adaptor, anddetermining a value of the charging voltage of the DC-charging powersource adaptor from the current voltage of the battery core.

Further to the method above for charging a mobile terminal, anembodiment of the disclosure further provides a mobile terminalincluding: a battery configured to store electrical energy; a USBinterface configured to be engaged with an external device; and amicroprocessor configured to determine whether two differential datapins of the USB interface are shorted, upon detecting an external devicebeing inserted into the USB interface; and if so, to communicate withthe inserted external device, wherein if the external device is aDC-charging power source adaptor, then the DC-charging power sourceadaptor switches two communication pins of a charging interface thereoffrom being shorted by default to being disconnected, and communicateswith the microprocessor; and the microprocessor detects voltage of thebattery after communicating successfully with the DC-charging powersource adaptor, and if the voltage of a battery core lies in a rangedelimited by preset DC-charging thresholds, then the microprocessorcontrols the battery to be DC-charged using charging voltage output bythe DC-charging power source adaptor, and determines a value of thecharging voltage of the DC-charging power source adaptor from thecurrent voltage of the battery core.

In another aspect, an embodiment of the disclosure further provides amethod for charging by a DC-charging power source adaptor, the methodincluding: configuring two communication pins in a charging interface ofthe DC-charging power source adaptor to be shorted by default;controlling the two communication pins of the charging interface to bedisconnected, after the charging interface is connected with the mobileterminal; and communicating with the mobile terminal through thecommunication pins, and after the communication succeeds, determining avalue of charging voltage output by the DC-charging power source adaptorfrom current voltage of a battery core of the mobile terminal.

Further aspects and areas of applicability will become apparent from thedescription provided herein. It should be understood that variousaspects of this disclosure may be implemented individually or incombination with one or more other aspects. It should also be understoodthat the description and specific examples herein are intended forpurposes of illustration only and are not intended to limit the scope ofthe present disclosure.

DRAWINGS

The drawings described herein are for illustrative purposes only ofselected embodiments and not all possible implementations, and are notintended to limit the scope of the present disclosure.

FIG. 1 is a circuit scheme block diagram of an embodiment of a mobileterminal and a DC-charging power source adaptor according to thedisclosure;

FIG. 2 is a circuit scheme diagram of an embodiment of the DC-chargingpower source adaptor in FIG. 1;

FIG. 3 is a flow chart of a process of an embodiment of a chargingmethod according to the disclosure;

FIG. 4 is a flow chart of a process of an embodiment of a chargingmethod according to the disclosure;

FIG. 5 is a flow chart of an embodiment of detecting communicationbetween the mobile terminal and the DC-charging power source adaptorillustrated in FIG. 1;

FIG. 6 is a flow chart of an embodiment of a timed detection mechanismof communication between the mobile terminal and the DC-charging powersource adaptor illustrated in FIG. 1;

FIG. 7 is a flow chart of control in an embodiment of a DC-chargingcontrol strategy using a lookup table; and

FIG. 8 is a flow chart of control in an embodiment of avoltage-following DC-charging control strategy.

DETAILED DESCRIPTION

Example embodiments will now be described more fully with reference tothe accompanying drawings.

In the disclosure, a strategy to identify the type of charging isdesigned in a mobile terminal dependent upon configured communicationpins of a different external device so that the mobile terminalidentifies automatically the type of the externally connected chargingdevice. Also a specialized rapid charging mode is designed for aDC-charging power adaptor, so that a battery being charged routinely isDC-charged at large current to thereby significantly speed up chargingof the battery so as to shorten the period of time required for chargingthe mobile terminal, to alleviate such an influence upon the user in adaily access to the mobile terminal that arises from the mobile terminalbeing frequently charged for a long period of time, and to greatlyimprove the satisfactory of the user with the mobile terminal.

In the disclosure, a mobile terminal in which a chargeable battery isbuilt can identify automatically and accurately the type of a currentlyinserted external device to thereby invoke different charging managementmodes for different charging characteristics of different types ofexternal devices so as to make reasonable use of charging resources, andthe disclosure proposes a charging method for three types of externaldevices including a host, a normal power source adaptor, and aDC-charging power source adaptor. In this method, firstly acommunication mode of the DC-charging power source adaptor is configuredso that the DC-charging power source adaptor can exchange data with amobile terminal to be charged, preferably in the UART (UniversalAsynchronous Receiver/Transmitter) communication mode; and then acharging managing circuit in the mobile terminal is adapted toconfigured interface pins of the host and the normal power sourceadaptor currently charging through a USB data line so that the mobileterminal can identify automatically the three types of external devicesincluding the host, the normal power source adaptor, and the DC-chargingpower source adaptor.

Firstly hardware configurations of the mobile terminal and theDC-charging power source adaptor will be described below.

As illustrated in FIG. 1, in order to maintain the existing traditionalcharging function of the mobile terminal so that the mobile terminal canbe normally engaged with and charged by the existing host and normalpower source adaptor, the existing USB interface Ji of the mobileterminal is maintained in this embodiment, i.e., a reused interface forboth charging and transmitting data, e.g., the currently widely appliedUSB interface, so that the mobile terminal can be engaged with andpowered by the normal power source adaptor and computer host in themarket, which are currently manufactured by the majority of themanufactures. For the power pin VBUS in the USB interface Ji, in thisembodiment, one end thereof is connected with a power source managingchip in the mobile terminal, and another end thereof is connected withthe battery through a DC-charging switch, which can be any type ofcontrollable switch element with low conduction impedance through whichlarge current can pass, e.g., controllable silicon, an MOS transistor,etc., to receive a switch control signal output by a microprocessor inthe mobile terminal to selectively switch between the normal chargingmode and the rapid charging mode. For the two differential data pins D+and D− in the USB interface Ji, they are designed to be connected withthe microprocessor through a gating switch, which can be a double-poledouble-throw switch, to receive a control signal output by themicroprocessor, and if the externally connected charging device is thehost or the normal power source adaptor, the differential data pins D+and D− of the USB interface Ji are connected with the respectivedifferential data interfaces DP and DN of the microprocessor through thegating switch; and if it is detected that the differential data pins D+and D− of the USB interface Ji are shorted, then the gating switch iscontrolled by the microprocessor to switch the differential data pins D+and D− of the USB interface Ji to be connected with the respective UARTinterfaces TXD and RXD of the microprocessor to thereby identify whetherthe externally connected charging device is the normal power sourceadaptor or the DC-charging power source adaptor. The microprocessor inthe mobile terminal can be designed to conduct UART communication withthe externally connected power source adaptor after the differentialdata pins D+ and D− of the USB interface Ji are switched to be connectedwith the UART interfaces TXD and RXD of the microprocessor, and if thecommunication succeeds, to determine that the inserted external deviceis the DC-charging power source adaptor; otherwise, to determine thatthe inserted external device is the normal power source adaptor.

In this embodiment, the DC-charging power source adaptor is configuredin the UART communication mode instead of the I²C bus communication modefor the reason that there is small communication traffic, a low rate,and a high anti-interference capability of UART communication in theasynchronous communication mode to thereby avoid effectivelycommunication between the mobile terminal and the power source adaptorfrom becoming highly instable due to interference from current,impedance, voltage, and other signals so that the mobile terminal can becharged stably and rapidly at large current by the DC-charging powersource adaptor to thereby improve the safety of the mobile terminalbeing charged.

Of course, if the instability above is not taken into account, thencommunication between the mobile terminal and the DC-charging powersource adaptor can be designed in another communication mode than UART(e.g., the I²C bus communication mode, etc.) although this embodimentwill not be limited thereto.

FIG. 2 illustrates a schematic diagram of circuit components of aDC-charging power source adaptor supporting UART communication, wherethe DC-charging power source adaptor generally includes threecomponents, i.e., a charging interface Jo, a controlling module, and anAC-DC (converting) module, as illustrated in FIG. 1 as well, where apower source pin Vbus, a ground pin Gnd, and two communication pins Txand Rx are arranged in the charging interface Jo. The power source pinVbus configured to transmit a charging power source is connected withthe AC-DC module to transmit a DC power source output by the AC-DCmodule to the power source pin VBUS of the USB interface Ji of themobile terminal to charge the mobile terminal. The ground pin Gnd isconnected with the system ground of the DC-charging power sourceadaptor, and after the DC-charging power source adaptor is engaged withthe mobile terminal, the ground pin Gnd is connected with the ground pinGND of the USB interface Ji of the mobile terminal so that both of theground pins are grounded together. The two communication pins Tx and Rxof the charging interface Jo are shorted by default, and connected withthe respective UART interfaces TX and RX of the controlling module.

If the controlling module detects that the DC-charging power sourceadaptor is engaged with the mobile terminal, followed by a preset delayperiod of time (the preset period of time can be determined as afunction of a period of time from when the mobile terminal detects anexternal device being inserted to when the mobile terminal detects thatthe differential data pins D+ and D− thereof are shorted), then thecontrolling module will control the two communication pins Tx and Rx ofthe charging interface Jo to be switched from being shorted by defaultto be disconnected from each other, and then send a communicationcommand on its own initiative to the mobile terminal through the UARTinterfaces TX and RX thereof, conduct UART communication with the mobileterminal to exchange a handshake instruction with each other, receivecontrol information sent by the mobile terminal if the handshakesucceeds, and further adjust the volt value of the charging voltageoutput by the AC-DC module according to the control information so thatthe mobile terminal can be charged differently as required in differentphases. Of course, the mobile terminal can alternatively be configuredto be timed to send a UART communication command to the externallyconnected power source adaptor, and to wait for a response command fedback by the DC-charging power source adaptor, in a preset wait period oftime after the differential data pins D+ and D− of the USB interface Jiare switched to be connected with the UART interfaces TXD and RXD of themicroprocessor of the mobile terminal, and if a valid response commandis received in the wait period of time, to determine that the inserteddevice is the DC-charging power source adaptor; otherwise, to determinethat the inserted device is the normal power source adaptor. In thisembodiment, the wait period of time shall be longer than the presetperiod of time so that the DC-charging power source adaptor can receiveand respond to the UART communication command sent by the mobileterminal, after the communication pins Tx and Rx of the DC-chargingpower source adaptor are disconnected from each other.

Of course the controlling module can alternatively be designed tofurther control the two communication pins Tx and Rx of the charginginterface Jo to be switched to be connected with and disconnected fromeach other, upon reception of a specific pulse waveform sent by themobile terminal. The controlling module can be configured to firstlyconfigure by default the UART interfaces TX and RX thereof to receive aninput, and if the mobile terminal detects that the externally inserteddevice is a power source adaptor, and the microprocessor of the mobileterminal switches the UART interfaces TXD and RXD thereof to beconnected with the differential data pins D+ and D− of the USB interfaceJi, then firstly the specific pulse waveform will be output by themicroprocessor to the externally connected power source adaptor. If theexternally connected power source adaptor is the normal power sourceadaptor, then no response will be made to the specific pulse waveform.If the externally connected power source adaptor is the DC-chargingpower source adaptor, then the controlling module in the DC-chargingpower source adaptor will receive the specific pulse waveform even ifthe communication pins Tx and Rx are shorted because the UART interfacesTX and RX of the controlling module are configured to receive an input.The controlling module switches the communication pins Tx and Rx of thecharging interface Jo from being shorted by default to be disconnectedfrom each other, and resume the communication interface function of theUART interfaces TX and RX of the controlling module, upon reception ofthe specific pulse waveform. In order to enable DC-charging power sourceadaptors of different models to receive reliably the specific pulsewaveform, the microprocessor in the mobile terminal can be configured tosend constantly the specific pulse waveform for a preset period of timewhich can be determined as a function of a period of time from when theDC-charging power source adaptor receives the specific pulse waveform towhen the DC-charging power source adaptor controls the communicationpins Tx and Rx thereof to be connected with or disconnected from eachother. Thereafter the microprocessor initiates a communication commandon its own initiative to the externally connected power source adaptorin the UART communication mode, and if a valid command fed back by theexternal power source adaptor is received, then the microprocessordetermines that the external device is the DC-charging power sourceadaptor, and starts the rapid charging mode; and if there is no validcommand fed back, then the microprocessor determines that the externaldevice is the normal power source adaptor, and at this time themicroprocessor disconnects the UART interfaces TXD and RXD thereof fromthe differential data pins D+ and D− of the USB interface Ji, and startsthe normal DCP charging mode.

In order to adjust dynamically the charging voltage output by the AC-DCmodule, in this embodiment, a rectifying circuit, a transformer module,a synchronous rectification controller, a PWM controller, an opticalcoupler, a power MOS transistor, and other elements are designed in theAC-DC module; and a controller, a digital potentiometer, a currentdetecting chip, a boosting circuit, and other elements are designed inthe controlling module, as illustrated in FIG. 2, where the rectifyingcircuit receives an AC input power source AC IN provided by a mainsgrid, rectifies the AC input power source into a DC power source, andoutputs the DC power source to the transformer module for transformationinto the charging voltage to charge the mobile terminal. The UARTinterfaces TX2 and RX2 of the controller are connected with thecommunication pins Tx and Rx of the charging interface Jo through twosignal lines across which a switch K is connected, where the switch isclosed by default to short the communication pins Tx and Rx. If thecontroller receives the specific pulse waveform, or if the controllerdetects that the DC-charging power source adaptor is engaged with themobile terminal, followed by a preset delay period of time (dependentupon the configuration of the controller), then the controller willoutput a control signal to the switch K through an interface of thecontroller CTL2 (e.g., a branch of GPIO interface) to control the switchK to be opened, and further create a UART communication line between theDC-charging power source adaptor and the mobile terminal.

In this embodiment, the magnitude of the charging current output throughthe power source pin Vbus of the charging interface Jo can be detectedto thereby determine whether the DC-charging power source adaptor isconnected with the mobile terminal. If the DC-charging power sourceadaptor is not connected with the mobile terminal, then the chargingcurrent output through the power source pin Vbus will be substantiallyzero. If the DC-charging power source adaptor is connected with themobile terminal, then there may be some charging current even if thebattery of the mobile terminal is fully charged. Thus the DC-chargingpower source adaptor can determine from the magnitude of the chargingcurrent whether it is connected with the external mobile terminal.

In order to adjust dynamically the output voltage of the AC-DC module,in this embodiment, the digital potentiometer is designed in thecontrolling module to be connected with the controller. The controllergenerates a voltage adjusting instruction from the received controlinformation, and sends the voltage adjusting instruction to the digitalpotentiometer to change the resistance value of a valid resistor of thedigital potentiometer. In this embodiment, the controller can beconnected and communicates with the digital potentiometer over an I²Cbus, as illustrated in FIG. 2, to transmit the voltage adjustinginstruction. In order to ensure the stability of the signal beingtransmitted, in this embodiment, a voltage pull-up circuit is furtherconnected over the I²C bus, for example, a clock line SCL and a dataline SDA of the I²C bus are connected with a DC power source VDDrespectively through pull-up resistors R2 and R3 to thereby improve theanti-interference capability of the signal being transmitted.

The DC power source VDD can be embodied as a set of smallelectromagnetic coils designed separately in the transformer module. Theratio of the numbers of turns of a primary coil and a secondary coil inthe set of small electromagnetic coils is configured to transform the DCpower source output by the rectifying circuit into the desirable DCpower source VDD to power those components in the DC-charging powersource adaptor to provide the components with desirable DC operatingvoltage, e.g., the controller, the digital potentiometer, the currentdetecting chip, and other components to thereby enable them to operate

The digital potentiometer is a resistance-adjustable resistor element inwhich a resistor body is built. In this embodiment, the resistor bodyconnected in series with a current-limiting resistor R1 is connectedbetween the anode of a secondary coil in another set of electromagneticcoils (referred below simply to as the other set of electromagneticcoils) in the transformer module and the ground. Particularly one endPOA of the resistor body is connected with the anode of the secondarycoil in the other set of electromagnetic coils through thecurrent-limiting resistor R1 connected in series, and the other end POBof the resistor body is grounded. An intermediate tap POW of theresistor body is connected with a reference voltage pin VREF of thesynchronous rectification controller, and if the resistance value of thevalid resistor of the digital potentiometer varies, then the voltagevalue of the charging voltage output by the other set of electromagneticcoils in the transformer module will be adjusted in order to maintainthe reference voltage on the reference voltage pin VREF of thesynchronous rectification controller. In order to adjust the volt valueof the charging voltage, the synchronous rectification controlleradjusts its output control signal to the varying resistance value of thevalid resistor of the digital potentiometer, and transmits the controlsignal to the PWM controller after the control signal isoptic-electrically isolated by the optical coupler, to thereby adjust aduty ratio of a PWM signal output by the PW controller. The PWM signalis transmitted to the transformer module, and particularly can betransmitted to a switch transistor connected in series with thesecondary coil in the other set of electromagnetic coils, to control theswitch transistor to be switched on and off to thereby adjust theswitching timing of the other set of electromagnetic coils so as tofurther adjust the volt value of the charging voltage output by thesecondary coil thereof for the purpose of adjusting dynamically thecharging voltage.

In this embodiment, the charging voltage output by the transformermodule can be finely adjusted in the range of 3.6V to 12V to therebycharge different mobile terminals as required in reality.

In order to achieve the stability of the charging voltage output by thetransformer module, in this embodiment, instead of a traditionalrectification scheme in which a diode is connected in series on acharging voltage transmission line, the power MOS transistor isconnected on the charging voltage transmission line and switched on oroff by the switching signal output by the synchronous rectificationcontroller to thereby shape the waveform of the charging voltage outputby the transformer module.

In this embodiment, the power MOS transistor can be embodied as an NMOStransistor connected between the cathode of the secondary coil in theother set of electromagnetic coils and the ground pin Gnd of thecharging interface Jo. Since the DC-charging power source adaptorsupports an output of large current, if the charging voltage output bythe transformer module is shaped by the diode, then power consumption ofthe DC-charging power source adaptor may be increased and the efficiencyin charging may be lowered due to a significant voltage drop across theconducting diode. In this embodiment, the charging voltage is shaped bythe power MOS transistor, and since the power MOS transistor has lowinner resistance and supports large current passing, systematic powerconsumption of the DC-charging power source adaptor can be loweredeffectively and the efficiency in charging the mobile terminal can beimproved.

In order to detect in real time charging current output by thetransformer module to thereby improve the safety in charging, in thisembodiment, a sampling resistor R6 is further connected in series in thetransmission line of the charging current, as illustrated in FIG. 2,preferably between the anode of the secondary coil in the other set ofelectromagnetic coils in the transformer module and the power source pinVbus of the charging interface Jo, and inputs −IN and +IN of the currentdetecting chip are connected with two ends of the sampling resistor R6to acquire a voltage drop across the resistor R6, and after the voltagedrop is amplified, the magnitude of the charging current is calculatedfrom the voltage drop and the resistance value of the sampling resistorR6. The current detecting chip generates sample voltage corresponding tothe calculated magnitude of the charging current, and transmits thesample voltage to an ADC interface AD1 of the controller through anoutput OUT thereof, and the sample voltage is analog-to-digitalconverted by the controller into the magnitude of the charging current,so the controller can detect in real time the charging current.

If the range of the amplitude of the sample voltage output by thecurrent detecting chip exceeds an interface voltage range specified bythe ADC interface AD1 of the controller, then the ADC interface of thecontroller may be damaged. In order to protect the controller, anoffload circuit can be additionally arranged between the output OUT ofthe current detecting chip and the ADC interface AD1 of the controller,e.g., a resistor offload circuit composed of resistors R4 and R5, toadjust the voltage signal output by the current detecting chip withinthe interface voltage range acceptable to the AD1 interface of thecontroller so as to avoid the ADC interface AD1 of the controller frombeing damaged due to the input voltage being too high.

In order to improve the safety in charging so that the DC-charging powersource adaptor can have the charging power source disconnected rapidlyupon abnormal charging occurring to thereby avoid the mobile terminalfrom being damaged, in this embodiment, a switch transistor Q1supporting large current passing is further arranged in the chargingpower source transmission line of the DC-charging power source adaptorso that a switch voltage, generated by the boosting circuit, sufficientto drive the switch transistor Q1 to be switched on is transmitted to acontrol pole of the switch transistor Q1 to control the switchtransistor Q1 to be switched on or off to thereby have the chargingpower source transmission line connected or disconnected.

In this embodiment, the switch transistor can be embodied preferably asa pair of NMOS transistors Q1 in which parasitic diodes connected inanti-parallel are built, as illustrated in FIG. 2. The pair of NMOStransistors Q1 are switched on and connected in series in thetransmission line of the charging power source, where the sources of thetwo NMOS transistors in the pair of NMOS transistors Q1 can beconnected, the drains of the two NMOS transistors can be connectedrespectively with the anode of the secondary coil in the other set ofelectromagnetic coils in the transformer module, and the power sourcepin Vbus of the charging interface Jo; and then the gates of the twoNMOS transistors can be connected with the boosting circuit. An enableend of the boosting circuit is connected with the controller to receivean enable signal output by the controller. During charging, if thecontroller detects normal charging current, then the controller willoutput the valid enable signal to control the boosting circuit to beenabled into operation to boost the DC power source output by thetransformer module to the switch voltage higher than the volt value ofthe charging voltage, and the switch voltage is output to the gates ofthe pair of NMOS transistors Q1 to control the pair of NMOS transistorsQ1 to be switched on to have the transmission line of the charging powersource connected, so that the charging power source can be output to theexternally connected mobile terminal to charge the battery in the mobileterminal. If the controller detects abnormal charging current orreceives control information sent by the mobile terminal to stopcharging, then the controller will output the invalid enable signal tocontrol the boosting circuit to stop operating. At this time the pair ofNMOS transistors Q1 is switched off due to the disappearing voltage atthe gates thereof, to thereby have the transmission line of the chargingpower source disconnected to block the charging power source fromoutputting to the outside, so that the DC-charging power source adaptorcan be controlled to stop powering the mobile terminal.

A charging method operating on the mobile terminal and the DC-chargingpower source adaptor will be described below with reference to thehardware configurations illustrated in FIG. and FIG. 2.

As illustrates in FIG. 4, the charging control flow thereof generallyinvolves the following steps:

S401. The mobile terminal detects an inserted external device, andperforms subsequent steps upon detecting an external device beinginserted.

In this embodiment, an inserted external device can be detected as inthe prior art, for example, by detecting a DC power source accessing thepower source pin VBUS of the USB interface Ji of the mobile terminal. Inthe traditional host charging mode SDP and normal power source adaptorcharging mode DCP, the charging voltage output by the host and thenormal power source adaptor is typically 5V; and the DC-charging powersource adaptor can be configured to output by default the same constantcharging voltage as the host and the normal power source adaptor, e.g.,5V constant charging voltage so that the mobile terminal cansubstantially determine whether the DC-charging power source adaptor isinserted.

Of course the 5V constant charging voltage here only relates to anembodiment, and for some mobile terminal to be charged at constantvoltage of another volt value, the DC-charging power source adaptor willbe simply configured to output by default the same constant chargingvoltage as the charging voltage output by the normal power sourceadaptor when the normal power source adaptor powers the mobile terminal.

S402. The mobile terminal detects the type of the inserted externaldevice.

In this embodiment, the mobile terminal operates by default withoutbeing DC-charged, that is, the microprocessor in the mobile terminalcontrols by default the DC-charging switch to be opened to have thepower source pin VBUS of the USB interface Ji connected with the powersource managing chip. Also the microprocessor controls the gating switchto be kept in the default state to have the differential data pins D+and D− of the USB interface Ji connected with the differential datainterfaces DP and DN of the microprocessor.

Whether the inserted external device is the host or the normal powersource adaptor can be determined as in the existing BC1.2 charging typedetection scheme. Of course this can alternatively be determinedparticularly as follows, as illustrated in FIG. 3:

If the mobile terminal detects an external device being inserted intothe charging interface thereof, then the microprocessor firstlydetermines whether the differential data pins D+ and D− of the USBinterface Ji are shorted, and if not so, then the mobile terminaldetermines that the inserted external device is the host because theexisting host (particularly the computer host) typically is connectedand communicates with and powers the mobile terminal through the USBdata line. Of course the mobile terminal can further conduct USBcommunication with the externally inserted external device via thedifferential data interfaces DP and DN of the microprocessor to furtherdetermine whether the inserted external device is the host. If it isdetected that the differential data pins D+ and D− of the USB interfaceJi are shorted, then the mobile terminal determines that the insertedexternal device is a power source adaptor because the communication pinsof the existing normal power source adaptor typically are configured tobe shorted. Moreover in this embodiment, in order to be identified bythe mobile terminal in the same way as the normal power source adaptor,the communication pins Tx and Rx of the DC-charging power source adaptorcan also be configured to be shorted by default. If the mobile terminaldetermines that the inserted external device is a power source adaptor,then the mobile terminal can communicate with the externally connectedpower source adaptor to further determine whether the inserted externaldevice is the normal power source adaptor or the DC-charging powersource adaptor. Particularly if the microprocessor detects that thedifferential data pins D+ and D− of the USB interface Ji of the mobileterminal are shorted, then the microprocessor firstly controls thegating switch to operate to switch the differential data pins D+ and D−of the USB interface Ji to be connected with the UART interfaces TXD andRXD of the microprocessor. Then the microprocessor outputs a specificpulse waveform to the externally connected power source adaptor throughthe UART interfaces TXD and RXD of the microprocessor in a preset periodof time. After the preset period of time expires, the microprocessorinitiates a communication command on its own initiative to theexternally connected power source adaptor in the UART communicationmode, and if a valid response command fed back by the externallyconnected power source adaptor is received, then the microprocessordetermines that the inserted external device is the DC-charging powersource adaptor (because at this time the DC-charging power sourceadaptor has the communication pins Tx and Rx of the charging interfaceJo thereof switched from being shorted to be connected with the UARTinterfaces TX2 and RX2 of the controller thereof); otherwise, themicroprocessor determines that the inserted external device is thenormal power source adaptor.

Of course, the microprocessor can alternatively determine thisotherwise, for example, after the microprocessor controls the UARTinterfaces TXD and RXD thereof to be connected with the respectivedifferential data pins D+ and D− of the USB interface Ji, themicroprocessor waits for reception of a UART communication commandinitiated by the DC-charging power source adaptor on its own initiative.If the UART communication command is received in a preset wait period oftime, then the mobile terminal determines that the inserted externaldevice is the DC-charging power source adaptor; otherwise, the mobileterminal determines that the inserted external device is the normalpower source adaptor. Alternatively the microprocessor is timed to senda UART communication command to the externally connected power sourceadaptor, and waits for a response command fed back by the external powersource adaptor, in a preset wait period of time, and if a valid responsecommand is received, then the mobile terminal determines that theinserted external device is the DC-charging power source adaptor;otherwise, the mobile terminal determines that the inserted externaldevice is the normal power source adaptor.

If the microprocessor determines that the inserted external device isthe DC-charging power source adaptor, in order to enable a betterswitching mechanism and error-tolerant mechanism, in this embodiment,communication between the mobile terminal and the DC-charging powersource adaptor can be detected in this embodiment preferably as follows,as illustrated in FIG. 5:

The microprocessor initiates a communication command A on its owninitiative to the external power source adaptor after switching thecommunication interface of the microprocessor from the differential datainterfaces DP and DN to the UART interfaces TXD and RXD, and also countsthe number of communications. The DC-charging power source adaptorreceiving successfully the communication command A can respondaccordingly by sending a communication command B to the mobile terminal,and if the mobile terminal does not receive any valid communicationcommand B, then the microprocessor firstly determines the count ofcommunications at that time, and if the count of communications is lessthan 2, then the microprocessor retransmits the communication command Afor a second attempt on communication; and if the count ofcommunications is more than or equal to 2, then the microprocessordetermines that the communication fails, and disconnects thedifferential data pins D+ and D− of the USB interface Ji of the mobileterminal from the UART interfaces TXD and RXD of the microprocessor toresume the original state where the differential data pins D+ and D− ofthe USB interface Ji are connected with the differential data pins DPand DN of the microprocessor. If the mobile terminal receivessuccessfully the communication command B, then the microprocessordetermines that the communication succeeds, and resets the count ofcommunications, and thereafter can start a timed communication detectingmechanism as illustrated in FIG. 6.

In the timed communication detecting mechanism, the mobile terminal istimed to send a handshake instruction, e.g., a communication instructionC, to the DC-charging power source adaptor, and also increments thecount of communications by one; and if the DC-charging power sourceadaptor receives successfully the communication instruction C, then itfeeds immediately a response instruction back to the mobile terminal,for example, it sends a communication instruction D to the mobileterminal. If the mobile terminal receives successfully the communicationinstruction D, then the handshake succeeds, and the mobile terminaldetermines that the communication between them is normal, maintains thecurrent charging process, resets the count of communications, and waitsfor arrival of a next timed detection period and then initiates againthe communication instruction C. If the mobile terminal does not receivethe communication instruction D, then the mobile terminal retransmitsthe communication instruction C to the DC-charging power source adaptor,and if both of the communications fail, then the mobile terminaldetermines that the DC-charging power source adaptor engaged therewithbecomes abnormal. In order to ensure the safety of the mobile terminal,at this time the microprocessor has the connection line between the USBinterface Ji of the mobile terminal and the internal system circuitsthereof disconnected, and notifies the user of the abnormality of theexternally connected power source adaptor to thereby alert the user.

S403. The mobile terminal enters a corresponding charging mode accordingto the detected type of the external device.

In this embodiment, if the inserted external device is detected as thehost or the normal power source adaptor, then the battery is charged bythe power source managing chip in the standard SDP charging mode (if thehost is inserted) or the standard DCP charging mode (if the normal powersource adaptor is inserted).

Particularly the microprocessor controls the DC-charging switch to bekept in the defaulted Off state, and also starts the power sourcemanaging chip to receive the charging voltage input by the host or thenormal power source adaptor, and to enter different charging phasesaccording to current voltage of the battery core. By way of an example,for a 4.2V chargeable battery (4.2V voltage of the core battery beingfully charged), if the core voltage is less than 3.5V, then the powersource managing chip enters a small-current pre-charging phase in which500 mA charging current is output, and the battery is pre-charged at thesmall current. If the voltage of the core battery lies between 3.5V and4.1V, then the power source managing chip enters a constant-currentcharging phase in which 1 A or 1.5 A charging current is output, and thebattery is charged at the constant current. The battery is charged inthe constant-current charging phase in the majority of the entirecharging process, and typically it takes approximately 90% of the entirecharging period of time for the voltage of the core battery to rise from3.5V to 4.1V. If the voltage of the core battery rises above 4.1V, thenthe power source managing chip enters a constant-voltage charging phasein which constant voltage is output to charge the battery, and at thistime the charging current is gradually decreased with the rising voltageof the battery until the battery is fully charged.

If the inserted external device is detected as the DC-charging powersource adaptor, then the mobile terminal operates in a subsequent rapidcharging mode.

S404. The mobile terminal determines whether the voltage of the corebattery lies in a range delimited by DC-charging thresholds, and if so,then the mobile terminal performs a subsequent large-current DC-chargingprocess; otherwise, the battery is charged by the source power managingchip.

In this embodiment, the DC-charging thresholds (a lower voltagethreshold S1 and an upper voltage threshold S2) can be determinedparticularly dependent upon the real condition of the battery topreferably agree with the voltage range of the battery corresponding tothe constant-current charging phase in the normal DCP charging mode. Forexample, the lower voltage threshold S1 and the upper voltage thresholdS2 of the 4.2V chargeable battery above can be set to S1=3.5V andS2=4.1V. If the voltage V_(bat) _(_) _(real) of the battery core isV_(bat) _(_) _(real)<3.5V or V_(bat) _(_) _(real)>4.1V, then themicroprocessor controls the DC-charging switch to be kept in the defaultOff state, and also starts the power source managing chip to receive theconstant charging voltage input by the DC-charging power source adaptor,e.g., DC 5V charging voltage, to pre-charge the battery at small current(for V_(bat) _(_) _(real)<3.5V) or at constant voltage (for V_(bat) _(_)_(real)>4.1V), that is, the battery is charged in the same charging modeas the host and the normal power source adaptor. If the voltage V_(bat)_(_) _(real) of the battery core is detected in the range [3.5V, 4.1V]delimited by the DC-charging thresholds, then the mobile terminal entersthe subsequent DC-charging process.

S405. The mobile terminal communicates with the DC-charging power sourceadaptor via the UART interfaces thereof, adjusts dynamically thecharging voltage output by the DC-charging power source adaptor to thevarying voltage of the core battery, and controls the DC-charging switchto be closed to short the power source managing chip so that the powersource managing chip stops operating, and the charging voltage istransmitted directly to the battery to DC-charge the battery.

In this embodiment, the charging voltage can be adjusted dynamically inany one of the following three preferred designed approaches:

In a first designed approach, a relationship reference table between thevoltage of the core battery and the target charging voltage is preset inthe mobile terminal, the voltage of the core battery is detected, andthe reference table is searched using the core voltage for the targetcharging voltage corresponding to the core voltage to control thevoltage output of the DC-charging power source adaptor.

The voltage of the core battery can be divided into several intervalsaccording to the range [S1, S2] delimited by the DC-charging thresholds,for example, the core voltage is divided into N intervals at a step of100 mV, where N=(S2−S1)/100 mV. For each interval, a target chargingvoltage value V_(out), a target charging current value I_(targ), and acharging current maximum value I_(max) corresponding to the core voltagein the interval are predetermined, and the reference table is createdand stored in the microprocessor, or in a memory in the mobile terminal,connected with the microprocessor for invoking by the microprocessor.

After entering the DC-charging process, as illustrated in FIG. 7, themicroprocessor is timed to detect the voltage V_(bat) _(_) _(real) ofthe battery core, searches the reference table using the detected corevoltage V_(bat) _(_) _(real), determines the core voltage interval inwhich the core voltage V_(bat) _(_) _(real) lies, and then searchesusing the determined interval for the target charging voltage valueV_(out), the target charging current value I_(targ), and the chargingcurrent maximum value I_(max) corresponding to the interval. Thereafterthe microprocessor conducts UART communication with the DC-chargingpower source adaptor, and sends the target charging voltage valueV_(out), the target charging current value I_(targ), and the chargingcurrent maximum value I_(max) to the DC-charging power source adaptor.

At the DC-charging power source adaptor side, the DC-charging powersource adaptor adjusts the resistance value of the valid resistor of thedigital potentiometer thereof according to the received target chargingvoltage value V_(out) to thereby change the charging voltage output bythe AC-DC module thereof to the target charging voltage value V_(out).At the end of the adjusting, the DC-charging power source adaptor sendsinformation E to the mobile terminal, detects in real time the realcharging current I_(chg) output by the AC-DC module, through the currentdetecting chip, and if |I_(chg)−I_(targ)|>I_(e) (I_(e) represents acontrollable range of the difference between the real charging currentvalue of the DC-charging power source adaptor and the target chargingcurrent value, and can be set to I_(e)=500 mA in this embodiment), orI_(chg)>I_(max), then the DC-charging power source adaptor determinesabnormal charging. At this time in order to ensure the safety incharging, the DC-charging power source adaptor outputs the invalidenable signal through the controller therein, as illustrated in FIG. 2,to control the boosting circuit to stop outputting the switch voltage,and to further control the pair of MNOS transistors Q1 to be switchedoff to thereby block the charging power source output by the AC-DCmodule from being transmitted to the mobile terminal. If|I_(chg)−I_(targ)|≤I_(e) and I_(chg)≤I_(max), then the DC-charging powersource adaptor ends this adjusting process, and DC-charges at largecurrent the battery in the mobile terminal using the adjusted chargingvoltage, where the charging current here can rise beyond 3500 mA, tothereby significantly speed up charging.

The following preferred scheme to create the reference table is proposedin this embodiment:

A number i of intervals, denoted as x_(i1)˜x_(i2), are set for the corevoltage in the range of [S1, S2];

For each of the intervals [x_(i1), x_(i2)], a target charging voltagevalue V_(out), a target charging current value I_(targ), and a chargingcurrent maximum value I_(max) corresponding to the interval arecalculated respectively in the equations of:V _(out) =V _(bat) _(_) _(real) +I _(targ)*(R _(line) +R _(board) +R_(bat))  (1)I _(targ) =I _(max) −ΔI  (2)I _(max)=min((V _(bat) _(_) _(max) −V _(bat) _(_) _(real))/R _(bat) , I_(allow))  (3)

Where R_(line) represents a resistance value on the charging line;R_(board) represents a resistance value on a circuit board of the mobileterminal; R_(bat) represents an inner resistance value of the battery,which can be experimentally measured; V_(bat) _(_) _(max) represents themaximum terminal voltage value supported by the battery, which shall bedetermined by a hardware platform on which the mobile terminal operates,and which shall be less than a specified safe value V_(bat) _(_) _(safe)of the terminal voltage of the battery; I_(allow) represents the maximumsafe charging current value selected while ensuring the safety of thebattery being charged; and ΔI represents a preset difference in current,which preferably lies in the range of [150 mA, 250 mA]; and

The reference table is created from the parameters V_(bat) _(_) _(real),V_(out), I_(targ) and I_(max).

In this embodiment, in order not to measure R_(line) and I_(max), thesum of the resistance value R_(line) on the charging line, and theresistance value R_(board) on the circuit board of the mobile terminalcan be calculated in the equation of:R _(line) +R _(board)=(V _(out) −V _(bat))/I _(chg)  (4)

Where V_(bat) represents the terminal voltage of the battery. That is,the terminal voltages V_(bat) of the battery, and the charging currentsI_(chg), for the different target charging voltage values V_(out) can bemeasured in reality, and substituted into Equation (4) to calculate thesum of R_(line) and R_(board), which is substituted into Equation (1) tocalculate the target charging voltage value V_(out).

In a preferred designed implementation of this embodiment, the targetcharging voltage value V_(out) and the charging current maximum valueI_(max) corresponding to each interval [x_(i1), x_(i2)] can becalculated preferably as follows: a lower bound x_(i1) of the corevoltage in the interval is used as V_(bat) _(_) _(real) and substitutedinto Equation (1) to calculate the target charging voltage value V_(out)corresponding to the interval; an upper bound x_(i2) of the core voltagein the interval is used as V_(bat) _(_) _(real) and substituted intoEquation (3) to calculate the charging current maximum value I_(max)corresponding to the interval; and further the target charging currentvalue I_(targ) is derived from calculated I_(max) in Equation (2), andthe reference table is created.

By way of an example, still taking the 4.2V chargeable battery as anexample, for the system powered by the battery, from the perspective ofthe safety of voltage to power the device, the terminal voltage V_(bat)of the battery shall not be more than a specific V_(bat) _(_) _(max)dependent upon the platform, and less than the specified safe valueV_(bat) _(_) _(safe) of the terminal voltage of the battery. If the safevalue V_(bat) _(_) _(safe) of the terminal voltage of the battery isV_(bat) _(_) _(safe)=4500 mV, then V_(bat) _(_) _(max)=4470 mV can betaken, so the terminal voltage V_(bat) of the battery is V_(bat)=V_(bat)_(_) _(real)+I_(chg)*R_(bat) _(_)≤4470.

From the perspective of the safety of the battery, if the maximum safecharging current value is taken as I_(allow)=4000 mA, then the chargingcurrent maximum value I_(max) is calculated as follows in Equation (3):I _(max)=min((4470−V _(bat) _(_) _(real))/R _(bat), 4000)  (5)

If the inner resistance R_(bat) of the battery is R_(bat)=100 mΩ, theother impedance is R_(line)+R_(board)=100 mΩ, and the range delimited bythe DC-charging thresholds of the battery is [3500 mV, 4100 mV] at astep of 100 mV, then the range [3500 mV, 4100 mV] delimited by theDC-charging thresholds can be divided into 6 intervals; an upper boundof the core voltage in each interval is substituted into Equation (5) tocalculate the charging current maximum value I_(max); the targetcharging current value I_(targ) is derived from calculated I_(max) inEquation (2), and ΔI=200 mA is taken in this embodiment; and a lowerbound of the core voltage in each interval is substituted into Equation(1) to calculate the target charging voltage value V_(out) fromcalculated I_(targ), so the desirable reference table is created asfollows:

V_(bat) _(—) _(real) (mV) V_(out) (mV) I_(targ) (mA) I_(max) (mA)3500-3600 4260 3800 4000 . . . . . . . . . . . . 4000-4100 4700 35003700

The reference table reflects to some extent the correspondencerelationship between the voltage of the core battery, and the chargingcurrent and the charging voltage output by the adaptor, but there may bea minor error relative to the real correspondence relationship, so thebattery can be experimentally charged, the charging voltage varying withthe varying charging current is recorded, and the values of theparameters in the reference table are adjusted, for example, the valuesof the respective parameters in the reference table are adjusted totheir ideal values by averaging them.

The target charging voltage obtained by looking up from the table is atheoretical value, and in reality, the inner resistance of the battery,and the impedance on the line may vary with temperature, aging, andother factors, so the real charging current value I_(chg) output by theDC-charging power source adaptor may deviate to some extent from thetarget charging current value I_(targ), thus resulting in some influenceupon the charging speed. In order to raise the charging current as muchas possible in an allowable range to further speed up charging, in thisembodiment, a charging current self-adjusting algorithm is introduced atthe DC-charging power source adaptor side, that is, after theDC-charging power source adaptor adjusts the output voltage to V_(out),if I_(targ)−I_(e)≤I_(chg)<I_(targ), then V_(out)=V_(out)+ΔV is adjustedprogressively so that the real charging current value I_(chg) output bythe DC-charging power source adaptor approaches progressively the targetcharging current value I_(targ).

In this embodiment, V_(out) can be adjusted preferably for five times byan amount which can be estimated in Equation (1), and if V_(bat) _(_)_(real) and R (including the inner resistance of the battery, the lineresistance, and all the other impedances) are invariable, then ΔV=ΔI*R.In this embodiment, ΔV is preferably set to ΔV=10 mV.

In a second designed approach, a relationship reference table betweenthe voltage of the core battery and the target charging voltage ispreset at the DC-charging power source adaptor side, and the DC-chargingpower source adaptor searches the reference table using the receivedcore voltage (detected and provided by the mobile terminal) for thetarget charging voltage value corresponding to the core voltage.Thereafter the DC-charging power source adaptor adjusts the outputvoltage thereof to the target charging voltage value to DC-charge thebattery built in the mobile terminal at large current.

Reference can be made for the related description in the first designedapproach above for creation of the reference table.

Noted that after entering the DC-charging process, at the mobileterminal side, the microprocessor is timed to detect the voltage V_(bat)_(_) _(real) of the battery core, conducts UART communication with theDC-charging power source adaptor, and is timed to send the detected corevoltage V_(bat) _(_) _(real) to the DC-charging power source adaptor.

At the DC-charging power source adaptor side, the DC-charging powersource adaptor searches the stored reference table thereof using thereceived core voltage V_(bat) _(_) _(real), determines the core voltageinterval in which the core voltage V_(bat) _(_) _(real) lies, and thensearches using the determined interval for the target charging voltagevalue V_(out), the target charging current value I_(targ), and thecharging current maximum value I_(max) corresponding to the interval.Then the controller adjusts the resistance value of the valid resistorof the digital potentiometer to thereby change the charging voltageoutput by the AC-DC module thereof to the target charging voltage valueV_(out). At the end of the adjusting, the DC-charging power sourceadaptor sends information E to the mobile terminal, and sends I_(targ)and I_(max) to the mobile terminal for detection of abnormal charging.At the same time the DC-charging power source adaptor detects in realtime the real charging current value I_(chg) output by the AC-DC module,through the current detecting chip thereof, and if|I_(chg)−I_(targ)|>I_(e) or I_(chg)>I_(max), then the DC-charging powersource adaptor determines abnormal charging, disconnects the chargingpower source from being output, and stops charging the mobile terminal.If |I_(chg)−I_(targ)|≤I_(e) and I_(chg)≤I_(max), then the DC-chargingpower source adaptor ends this adjusting process.

Also the charging current self-adjusting algorithm described in thefirst designed approach above can be introduced at the DC-charging powersource adaptor side so that the real charging current value I_(chg)output by the DC-charging power source adaptor can approachprogressively the target charging current value I_(targ) to therebyfurther speed up charging.

The table-lookup approach above relating to segmentedconstant-current-like charging can reduce the count of times that theoutput voltage of the DC-charging power source adaptor is adjusted, butthe output voltage is constant for a period of time, and the chargingcurrent is decreasing gradually with the ever rising voltage of the corebattery, thus resulting in some influence upon the charging speed of thebattery.

In order to enable the charging current to be maintained at a stablehigh level, DC-charging control by following in real time the varyingcore voltage is proposed in this embodiment as described in details inthe following third designed approach.

In the third designed approach, the target charging voltage value isadjusted in real time by following dynamically the varying voltage ofthe core battery.

As illustrated in FIG. 8, after entering the DC-charging process, themicroprocessor in the mobile terminal is timed to detect the voltageV_(bat) _(_) _(real) of the battery core, calculates the target chargingvoltage value V_(out), the target charging current value I_(targ), andthe charging current maximum value I_(max) in Equations (1) to (4), andsends these values to the DC-charging power source adaptor.

The DC-charging power source adaptor adjusts the resistance value of thevalid resistor of the digital potentiometer thereof according to thereceived target charging voltage value V_(out) to thereby adjust thecharging voltage output by the AC-DC module thereof to the targetcharging voltage value V_(out). At the end of the adjusting, theDC-charging power source adaptor sends information E to the mobileterminal, and also detects the charging current I_(chg) output by theDC-charging power source adaptor, through the current detecting chip,and if |I_(chg)−I_(targ)|>I_(e) or I_(chg)>I_(max), then the DC-chargingpower source adaptor determines abnormal charging, disconnects thecharging power source from being output by the DC-charging power sourceadaptor to the outside, and notifies the mobile terminal of abnormalcharging. If |I_(chg)−I_(targ)|≤I_(e) and I_(chg)≤I_(max), then theDC-charging power source adaptor ends this adjusting process, or startsthe charging current self-adjusting algorithm above to finely adjust thecharging voltage for at most five times (or another number of times), sothat the real charging current value I_(chg) output by the DC-chargingpower source adaptor approaches progressively the target chargingcurrent value I_(targ) to thereby speed up charging as much as possible.

S406. The mobile terminal determines whether the voltage of the corebattery exceeds the range delimited by the DC-charging thresholds, andif not, then the flow returns to the step S405; otherwise, the flowproceeds to a subsequent step.

S407. The microprocessor controls the DC-charging switch to be opened todisconnect the DC-charging pathway, and instructs the DC-charging powersource adaptor to adjust the output voltage thereof to the defaultconstant charging voltage, e.g., 5V DC-charging voltage, and to startthe power source managing chip to receive the constant charging voltageto charge the battery at the constant voltage until the battery is fullycharged.

In order to ensure the safety of the mobile terminal being charged, thefollowing charging abnormality handling mechanism is proposed in thisembodiment:

1. At the mobile terminal side

(1) The mobile terminal detecting that it is being powered by theDC-charging power source adaptor is timed to send a handshakeinstruction to the DC-charging power source adaptor, and waits for apreset period of time until the DC-charging power source adaptor feedsback response information, and if the mobile terminal receives theresponse information, then the handshake succeeds, and the mobileterminal is further charged; otherwise, the mobile terminal determinesabnormal charging, disconnects the connection line between the charginginterface of the mobile terminal and the system circuit, and notifiesthe user of the power source adaptor being abnormal;

(2) After entering the DC-charging process, if the mobile terminaldetects that the DC-charging power source adaptor is pulled outsuddenly, then it disconnects the DC-charging pathway between thecharging interface of the mobile terminal and the battery, and has thecharging interface connected with the power source managing chip;

(3) After entering the DC-charging process, if the mobile terminaldetects that the terminal voltage of the battery exceeds the presetthreshold (the threshold of the terminal voltage of the 4.2V chargeablebattery can be preset to 4.6V), then it disconnects the DC-chargingpathway between the charging interface of the mobile terminal and thebattery, and instructs the DC-charging power source adaptor to outputthe constant charging voltage, e.g., 5V DC voltage;

(4) After entering the DC-charging process, the mobile terminal detectsin real time the received real charging current value I_(chg), and ifthe absolute value of the difference between I_(chg) and I_(targ) goesbeyond the preset controllable range of the difference, then itdisconnects the DC-charging pathway between the charging interface ofthe mobile terminal and the battery, and switches to the power sourcemanaging chip to charge the battery; and

(5) After entering the DC-charging process, the mobile terminal detectsin real time the received real charging current value I_(chg), and ifI_(chg) is more than I_(max), then it disconnects the DC-chargingpathway between the charging interface of the mobile terminal and thebattery, and notifies the user of the power source adaptor beingabnormal

2. At the DC-charging power source adaptor side

(1) The DC-charging power source adaptor obtaining the target chargingvoltage value V_(out), the target charging current value I_(targ), andthe charging current maximum value I_(max) detects in real time itsoutput real charging current value I_(chg), and if the absolute value ofthe difference between I_(chg) and I_(targ) goes beyond the presetcontrollable range of the difference, then the DC-charging power sourceadaptor stops outputting the charging power source, and flicks a lamp toalert the user;

(2) After entering the DC-charging process, the DC-charging power sourceadaptor detects in real time its output real charging current valueI_(chg), and if I_(chg) is more than I_(max), then it determinesabnormal charging, and disconnects the charging power source from beingoutput to avoid the mobile terminal from being damaged due to beingfurther powered.

Of course, the mobile terminal and the DC-charging power source adaptorcan alternatively exchange data wirelessly with each other asillustrated in FIG. 2. Particularly a wireless communication module,e.g., Bluetooth, WiFi, or another wireless communication module can bearranged in the controlling module of the DC-charging power adaptor tobe connected with the controller, possibly another branch of UARTinterfaces TX1 and RX1 of the controller; and a matching wirelesscommunication module, e.g., a Bluetooth chip, can be arranged in themobile terminal to be connected with the microprocessor. If the mobileterminal needs to exchange data with the DC-charging power adaptor, thencommunication instructions generated by the microprocessor and thecontroller can be sent to the wireless communication modules connectedtherewith for conversion into a wireless signal sent to theircounterparts. Due to the wireless communication, such a difference inground level between the power source adaptor and the mobile terminalcan be addressed that arises from a significant voltage drop across acharging line between the power source adaptor and the mobile terminalbeing charged at large current, where the difference in ground levelwould otherwise have degraded a quality of waveform of the communicationsignal, thus resulting in the instability of communication.

The charging method according to this disclosure can be widely appliedto a handset, a tablet computer, a notebook computer, a mobile powersource, and other mobile terminals so as to satisfy different chargingdemands of the user.

The foregoing description of the embodiments has been provided forpurposes of illustration and description. It is not intended to beexhaustive or to limit the disclosure. Individual elements or featuresof a particular embodiment are generally not limited to that particularembodiment, but, where applicable, are interchangeable and can be usedin a selected embodiment, even if not specifically shown or described.The same may also be varied in many ways. Such variations are not to beregarded as a departure from the disclosure, and all such modificationsare intended to be included within the scope of the disclosure.

The invention claimed is:
 1. A method for charging a mobile terminal,the method comprising: determining, by the mobile terminal, whether twodifferential data pins of a USB interface thereof are shorted, inresponse to detecting insertion of an external device into the USBinterface; in response to determining that the two differential datapins are shorted, detecting, by the mobile terminal, whether theinserted external device is a DC-charging power source adaptor, and inresponse to determining that the inserted external device is theDC-charging power source adaptor, detecting, by the mobile terminal,voltage of a battery core of the mobile terminal; when the voltage ofthe battery core lies in a range [S1, S2] delimited by presetDC-charging thresholds, controlling, by the mobile terminal, accordingto the current voltage of the battery core, the DC-charging power sourceadaptor to output charging voltage corresponding to the current voltageof the battery core to DC-charge the battery, wherein the range [S1,S2]delimited by the DC-charging thresholds is consistent with a voltagerange of the battery core corresponding to a constant-current chargingphase in a normal DCP charging mode; and when the voltage of the batterycore goes out of the range delimited by the DC-charging thresholds,instructing, by the mobile terminal, the DC-charging power sourceadaptor to output a constant charging voltage that is output by theDC-charging power source adaptor by default, and receiving, by themobile terminal, the constant charging voltage output by the DC-chargingpower source adaptor; wherein when the voltage of the battery core isless than S1, the battery is pre-charged by a power source managing chipof the mobile terminal at a small current, and when the voltage of thebattery core is more than S2, the battery is charged by the power sourcemanaging chip of the mobile terminal at constant voltage.
 2. The methodfor charging the mobile terminal of claim 1, wherein detecting, by themobile terminal, whether the inserted external device is a DC-chargingpower source adaptor comprises: outputting, by the mobile terminal, asignal instructing the external device to switch two communication pinsof a charging interface of the external device from being shorted bydefault to being disconnected; and sending, by the mobile terminal, ahandshake instruction to the external device after a preset delay periodof time, and in response to receiving a successful handshakeacknowledgement, determining that the inserted external device is aDC-charging power source adaptor.
 3. The method for charging the mobileterminal of claim 2, further comprising: in response to receiving anacknowledgement indicating handshake failure or not receiving anacknowledgement, determining, by the mobile terminal, that the insertedexternal device is a normal power source adaptor, and starting thenormal DCP charging mode.
 4. The method for charging the mobile terminalof claim 1, wherein detecting, by the mobile terminal, whether theinserted external device is a DC-charging power source adaptorcomprises: waiting, by the mobile terminal, a preset wait period of timefor receiving a communication command from the external device; and inresponse to receiving the communication command, determining, by themobile terminal, that the inserted external device is a DC-chargingpower source adaptor.
 5. The method for charging the mobile terminal ofclaim 4, further comprising: in response to receiving no communicationcommand within the preset wait period of time, determining, by themobile terminal, that the inserted external device is a normal powersource adaptor, and starting the normal DCP charging mode.
 6. The methodfor charging the mobile terminal of claim 1, wherein detecting, by themobile terminal, whether the inserted external device is a DC-chargingpower source adaptor comprises: sending, by the mobile terminal, acommunication command to the external device at regular intervals, andwaiting for reception of a response command returned from the externaldevice, in a preset wait period of time, and in response to receiving avalid response command in the wait period of time, determining, by themobile terminal, that the inserted external device is a DC-chargingpower source adaptor.
 7. The method for charging the mobile terminal ofclaim 6, further comprising: in response to receiving no valid responsecommand in the wait period of time, determining, by the mobile terminal,that the inserted external device is a normal power source adaptor, andstarting the normal DCP charging mode.
 8. The method for charging themobile terminal of claim 1, the method further comprising: determining,by the mobile terminal, that the inserted external device is a host, andstarting a normal SDP charging mode, in response to detecting that thetwo differential data pins of the USB interface of the mobile terminalare not shorted.
 9. The method for charging the mobile terminal of claim1, wherein when controlling, by the mobile terminal, the DC-chargingpower source adaptor to output charging voltage corresponding to thecurrent voltage of the battery core according to the current voltage ofthe battery core, the method further comprises: sending, by the mobileterminal, a target charging current value I_(targ), and a chargingcurrent maximum value I_(max) to the DC-charging power source adaptor.10. A mobile terminal, comprising: a battery configured to storeelectrical energy; a USB interface configured to engage with an externaldevice; and a microprocessor configured: to determine whether twodifferential data pins of the USB interface are shorted, in response todetecting insertion of an external device into the USB interface; inresponse to determining that the two differential data pins are shorted,to detect whether the inserted external device is a DC-charging powersource adaptor; in response to determining that the inserted externaldevice is the DC-charging power source adaptor, to detect voltage of thebattery core V_(bat real), and if the voltage of the battery coreV_(bat real) lies in a range [S1, S2] delimited by preset DC-chargingthresholds, then to control, according to the current voltage of thebattery core, the DC-charging power source adaptor to output a chargingvoltage corresponding to the current voltage of the battery core toDC-charging the battery; and to perform one or more of: a firstDC-charging process where the microprocessor is configured to search areference table by using the detected voltage of the battery coreV_(bat real) to obtain a target charging voltage value V_(out)corresponding to an interval in which the detected voltage of thebattery core V_(bat real) belongs, and to transmit the target chargingvoltage value V_(out) to the DC-charging power source adaptor to controlthe DC-charging power source adaptor to output the charging voltage; ora second DC-charging process where the microprocessor is configured totransmit the detected voltage of the battery core V_(bat real) to theDC-charging power source adaptor to control the DC-charging power sourceadaptor to search a reference table by using the detected voltage of thebattery core V_(bat real) to obtain a target charging voltage valueV_(out) corresponding to an interval in which the detected voltage ofthe battery core V_(bat real) belongs, so the DC-charging power sourceadaptor outputs the charging voltage; or a third DC-charging processwhere the microprocessor is configured to calculate a target chargingvoltage value V_(out) according to the following:I_(targ)=I_(max)−ΔI;I_(max)=min((V_(bat max)−V_(bat real))/R_(bat), I_(allow)); andV_(out)=V_(bat real)+I_(targ)*(R_(line)+R_(board)+R_(bat)); whereR_(line) represents a resistance value on a charging line, R_(board)represents a resistance value on a circuit board of the mobile terminal,R_(bat) represents an inner resistance value of the battery, V_(bat max)represents a maximum terminal voltage value supported by the battery,V_(bat real) represents the voltage of the battery core, I_(allow)represents a maximum safe charging current value selected while ensuringthe safety of the battery being charged, ΔI represents a presetdifference in current, I_(max) represents a charging current maximumvalue, and I_(targ) represents a target charging current value, and themicroprocessor is configured to transmit the calculated target chargingvoltage value V_(out) to the DC-charging power source adaptor to controlthe DC-charging power source adaptor to output the charging voltage. 11.The mobile terminal of claim 10, further comprising: a DC-chargingswitch, connected between the USB interface and the battery, wherein themicroprocessor is configured to control the DC-charging switch inresponse to detecting that the voltage of the battery core lies in therange [S1, S2] delimited by the preset DC-charging thresholds, to closethe DC-charging switch to transmit the charging voltage output by theDC-charging power source adaptor directly to the battery to DC-chargethe battery; and a power source managing chip, connected between the USBinterface and the battery, wherein the microprocessor is configured tocontrol the power source managing chip in response to detecting that thevoltage of the battery core goes out of the range [S1, S2] delimited bythe preset DC-charging thresholds, to receive the charging voltageoutput by the DC-charging power source adaptor to charge the battery.12. A method for charging a mobile terminal, the method comprising:switching, by a DC-charging power source adaptor, two communication pinsin a charging interface of the DC-charging power source adaptor frombeing shorted by default to being disconnected in response to acondition that the charging interface of the DC-charging power sourceadaptor is inserted into a mobile terminal; receiving, by theDC-charging power source adaptor, controlling information including anindication to perform charging through the communication pins;determining, by the DC-charging power source adaptor, a value of acharging voltage to be output to the mobile terminal, and DC-charging abattery of the mobile terminal based on the value of the chargingvoltage, wherein the value of the charging voltage corresponds to thevoltage of the battery core of the mobile terminal, and the battery corelies in a range [S1, S2] delimited by preset DC-charging thresholds whendetermining, by the DC-charging power source adaptor, the value ofcharging voltage to be output to the mobile terminal; receiving, by theDC-charging power source adaptor, a target charging current valueI_(targ), and a charging current maximum value I_(max), sent by themobile terminal, or searching, by the DC-charging power source adaptor,the reference table for a target charging current value I_(targ), and acharging current maximum value I_(max) , corresponding to the currentvoltage of the battery core; and detecting in real time, by theDC-charging power source adaptor, charging current I_(chg) output by theDC-charging power source adaptor, and whenI_(targ)−I_(e)≤I_(chg)<I_(targ), progressively adjusting up, by theDC-charging power source adaptor, the charging voltage output by theDC-charging power source adaptor by an amount of ΔV, so the realcharging current I_(chg) output by the DC-charging power source adaptorapproaches the target charging current value I_(targ), or when theabsolute value of the difference between I_(chg) and I_(targ) is morethan I_(e) or I_(chg) is more than I_(max), stopping, by the DC-chargingpower source adaptor, the charging voltage from being output; whereinI_(e) represents a controllable range of a difference between the realcharging current value of the DC-charging power source adaptor and thetarget charging current value.
 13. The method for charging the mobileterminal of claim 12, wherein before switching, by the DC-charging powersource adaptor, two communication pins in the charging interface of theDC-charging power source adaptor from being shorted by default to beingdisconnected, the method further comprises: receiving, by theDC-charging power source adaptor, a signal instructing the DC-chargingpower source adaptor to switch two communication pins of the charginginterface of DC-charging power source adaptor from being shorted bydefault to being disconnected, sent by the mobile terminal.
 14. Themethod for charging the mobile terminal of claim 12, further comprising:after the charging interface of the DC-charging power source adaptor isinserted into the mobile terminal and followed by a preset delay periodof time, then switching, by the DC-charging power source adaptor, twocommunication pins in the charging interface of the DC-charging powersource adaptor from being shorted by default to being disconnected. 15.The method for charging the mobile terminal of claim 12, wherein beforereceiving, by the DC-charging power source adaptor, controllinginformation including an indication to perform charging through thecommunication pins, the method further comprises: after switching, bythe DC-charging power source adaptor, two communication pins in thecharging interface of the DC-charging power source adaptor from beingshorted by default to being disconnected, sending, by the DC-chargingpower source adaptor, a communication command on its own initiative tothe mobile terminal.
 16. The method for charging the mobile terminal ofclaim 12, wherein the DC-charging power source adaptor is configured tooutput constant charging voltage by default.